package com.cloudlibrary.service;

import com.cloudlibrary.domain.Book;
import com.cloudlibrary.domain.User;
import com.cloudlibrary.entity.PageResult;

/**
* @author lenove
* @description 针对表【book】的数据库操作Service
* @createDate 2024-12-12 15:23:12
*/
public interface BookService{
    PageResult selectNewBooks(Integer pageNum, Integer pageSize);
    Book findById(String id);
    Integer borrowBook(Book book);
    PageResult search(Book book, Integer pageNum, Integer pageSize);
    Integer addBook(Book book);
    Integer editBook(Book book);
    PageResult searchBorrowed(Book book, User user, Integer pageNum, Integer pageSize);
    boolean returnBook(String  id,User user);
    Integer returnConfirm(String id);
}
